package com.ljtxxhwj.myblob.service.impl;

import com.ljtxxhwj.myblob.entity.Subscribe;
import com.ljtxxhwj.myblob.mapper.SubscribeMapper;
import com.ljtxxhwj.myblob.service.SubscribeService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Collections;
import java.util.List;

@Service
public class SubscribeServiceImpl implements SubscribeService {
    @Autowired
    SubscribeMapper subscribeMapper;

    @Override
    public List<Subscribe> getSubscribed(int userId) {
        return subscribeMapper.getSubscribed(userId);
    }

    @Override
    public void subscribeToSomeone(Subscribe subscribe) {
        subscribeMapper.subscribeToSomeone(subscribe);
    }
}
